<?php
$file = $_GET['file'];
$Bericht = "Weet U zeker dat u het bestand \"$file\" wilt leegmaken?";
$knoppen = "<table width=\"100%\"><tr><td width=\"50%\" style=\"text-align: center;\"><img src=\"JaBt.png\" OnClick=\"location.href='leegBestand.fnc.php?file=$file&ja=ja'\"></td><td width=\"50%\" style=\"text-align: center;\"><img src=\"NeeBt.png\" OnClick=\"window.close();\"></td></tr></table>";
$ja = $_GET['ja'];
if ($ja == "ja"){
	$knoppen = "<table width=\"100%\"><tr><td width=\"100%\" style=\"text-align: center;\"><img src=\"okBt.png\" OnClick=\"window.close();\"></td></tr></table>";
	$Bericht = "Bestand geleegd.";
$fol  = fopen($file, 'w')or die('FOUT::logbestand niet gevonden!');
fclose($fol);
}
?>
<html>
	<head>
		<title>Bestand legen</title>
		<link rel="stylesheet" type="text/css" href="styles.css" />
	</head>
	<body style="background-image:url('functionAskbg.png'); padding-top: 40px; font-size: 18px;">
		<p style="text-align: center;"><?echo$Bericht?></p><br /><br /><?echo$knoppen?>
			</body>
</html>